﻿@using DirectSell.Model.Money
@using Webdiyer.WebControls.Mvc;
@model PagedList<RealMoney>

<table class="table table-border table-bordered table-hover table-bg table-sort">
    <thead>
        <tr class="text-c">
            @*<th width="25"><input type="checkbox" name="" value=""></th>*@
            <th width="80">序号</th>
            <th width="100">会员编号</th>
            <th width="40">姓名</th>
            <th width="40">银行名称</th>
            <th width="40">银行账户</th>
            <th width="40">持卡人姓名</th>
            <th width="90">申请金额</th>
            <th width="90">实际到账</th>
            <th width="150">申请时间</th>
            <th width="70">处理时间</th>
            <th width="100">备注</th>
            <th width="100">状态</th>
            <th width="100">操作</th>
        </tr>
    </thead>
    <tbody>
        @{ int i = 0;}
        @foreach (var item in Model)
        {
            <tr class="text-c">
                <td>@(Model.StartItemIndex + i++)</td>
                <td>@item.UserCode</td>
                <td>@item.UserName</td>
                <td>@item.BankName</td>
                <td>@item.BankCode</td>
                <td>@item.CardHolder</td>
                <td>@item.Amount</td>
                <td><p style="color:red">@item.RealAmount</p></td>
                <td>@item.ApplyTime</td>
                @if (item.State != 0)
                {
                    <td>@item.HandleTime</td>
                }
                else
                {
                    <td>|</td>
                }
                <td>@item.Remark</td>
                @switch (item.State)
                {
                    case 0:
                        <td class="td-status"><span class="label label-purple radius">待审核</span></td>
                        break;
                    case 1:
                        <td class="td-status"><span class="label label-success radius">已审核</span></td>
                        break;
                    case 2:
                        <td class="td-status"><span class="label label-danger radius">已拒绝</span></td>
                        break;
                }
                <td class="td-manage">
                    @if (item.State == 0)
                {
                        <a style="text-decoration:none" onClick="Agree('@item.Id','@item.UserCode',1,@item.RealAmount)" title="确认"> <i class="Hui-iconfont">&#xe63f;</i></a>
                        <a style="text-decoration:none" class="ml-5" onClick="Refuse('@item.Id','@item.UserCode',2,@item.RealAmount)" href="javascript:;" title="拒绝"> <i class="Hui-iconfont">&#xe631;</i></a>
                    }
                    else
                    {
                        <span>|</span>
                    }
            </tr>
        }
    </tbody>
</table>

